#ifndef MENUELEMENT_H_
#define MENUELEMENT_H_

#include "Vector2D.h"
#include "TextureManager.h"
#include "PrintString.h"

//class GameManager;
class MenuElement
{
	protected:
	Vector2D position; //relative to the top left corner of the Menu, top left corner of the element
	Vector2D size;
	Vector2D * textureVertices;
	//GameManager * gameManager;
	//void (GameManager::*clickAction)(void);
	
	TextureManager * textureManager;
	int textureIndex;
	bool hasFocus;
	bool isClickable;
	
	PrintString * label;
	
	public:
	MenuElement(TextureManager * textureManager, char * textureName, Vector2D position, Vector2D size, Vector2D * textureVertices);
	MenuElement(char * label, TextureManager * textureManager, char * textureName, Vector2D position, Vector2D size, Vector2D * textureVertices);
	MenuElement(bool isClickable, char * label, TextureManager * textureManager, char * textureName, Vector2D position, Vector2D size, Vector2D * textureVertices);
	~MenuElement();
	
	virtual void Draw(Vector2D parentPosition);
	virtual bool Click(Vector2D parentPosition, Vector2D mousePosition);
	virtual void Clicked(Vector2D mousePosition);
	virtual bool HandleUserInput(unsigned char key, int modifier, bool isDepressed);
	char * GetContent();
	void SetContent(char * content);
};

#endif /*MENUELEMENT_H_*/
